using UnityEngine;
using System.Collections;
using System.Collections.Generic;

public class BuffDebuffManager {
	
	static string typeName = "BuffDebuff";
	
	static GenericManager<BuffDebuff> _m;
	static GenericManager<BuffDebuff> m
	{
		get
		{
			if(_m == null)
				_m = new GenericManager<BuffDebuff>(typeName);
			return _m;
		}
	}
	
	public static Dictionary<string,string> index
	{
		get
		{
			return m.index;
		}
	}
	
	public static BuffDebuff Load(string name)
	{
		return m.LoadObject(name);
	}
	
	public static bool isCustom(string name)
	{
		return m.isCustom(name);
	}
		
	public static BuffDebuff AddBuffDebuff(string name, string description, List<TemporaryBonus> modifications)
	{
		BuffDebuff a = new BuffDebuff();
		a.name = name;
		a.description = description;
		a.modifiers = modifications;
		
		return m.AddObject(a);
	}
	
	public static bool SaveBuffDebuff(BuffDebuff s, string file)
	{
		return m.SaveObject(s, file);
	}
	
	public static void DeleteBuffDebuff(string name)
	{
		m.DeleteObject(name);
	}
}
